package com.sgb.kjwl.view.ui.adapter.home;


import android.content.Context;

import com.sgb.kjwl.BR;
import com.sgb.kjwl.R;
import com.sgb.kjwl.model.entity.Bean;
import com.swgk.core.recyclerview.adapter.BaseRecycleAdapter;
import com.swgk.core.recyclerview.adapter.ItemViewHolder;

import java.util.List;

/**
 * 作者:张磊
 * 日期:2018/6/20
 * 说明:需求item
 */
public class ListDataAdapter extends BaseRecycleAdapter<Bean> {
    public ListDataAdapter(Context context, List<Bean> beans) {
        super(context, R.layout.listdata_adapter, beans);
    }

    @Override
    public void convert(ItemViewHolder holder, Bean item) {
        holder.setBinding(BR.viewModel, item);
        holder.setText(R.id.tv_name, item.no)
                .setText(R.id.tv_value, item.name);
    }

}
